'''
import gymnasium as gym
env = gym.make("CartPole-v1")
observation, info = env.reset()

for _ in range(1):
    action = env.action_space.sample()  # agent policy that uses the observation and info
    observation, reward, terminated, truncated, info = env.step(action)

    print(type(observation))

    if terminated or truncated:
        observation, info = env.reset()

env.close()
'''

import numpy as np

a=np.array((1,2,3,4,5,0,0,0,0),dtype=float)
print(a[0:5].mean(),a[0:5].var())

b=np.array((1,2,3,4,5),dtype=float)
print(b.mean(),b.var())